

package com.hazelcast.jet.impl.operation;

import com.hazelcast.jet.impl.JobSummary;
import com.hazelcast.jet.impl.execution.init.JetInitDataSerializerHook;
import com.hazelcast.spi.impl.operationservice.ReadonlyOperation;

import java.util.List;
import java.util.concurrent.CompletableFuture;

public class GetJobSummaryListOperation extends AsyncOperation implements ReadonlyOperation {

    public GetJobSummaryListOperation() {
    }

    @Override
    public CompletableFuture<List<JobSummary>> doRun() {
        return getJobCoordinationService().getJobSummaryList();
    }

    @Override
    public int getClassId() {
        return JetInitDataSerializerHook.GET_JOB_SUMMARY_LIST_OP;
    }
}
